/*
 * @Date: 2024-04-17 16:12:32
 * @LastEditTime: 2024-04-19 17:29:36
 */
import router from "./router";
import { ElMessage } from "element-plus";
import NProgress from "nprogress";
import "nprogress/nprogress.css";
import { getToken } from "@/utils/auth";
import { isRelogin } from "@/utils/request";

NProgress.configure({ showSpinner: false });

const whiteList = ["/", "/index", "/register", "/register/process", "/login"];
const redirectList = ["/register", "/register/process", "/login"];
router.beforeEach((to, from, next) => {
  NProgress.start();
  next();
});

router.afterEach(() => {
  NProgress.done();
});
